package sample.shapes;

import java.util.Enumeration;
import java.util.Iterator;
import java.util.Vector;

public class impShapes {

	public static void main(String[]args){
		Vector s=new Vector();
		s.add(new Circle());
		s.add(new Square());
		s.add(new Triangle());
		Enumeration e=s.elements();
		while(e.hasMoreElements()){
			((Shape)e.nextElement()).draw();
		}
		
		Iterator i=s.iterator();
		while(i.hasNext()){
			((Shape)i.next()).draw();
		}
	}
}
